<?php
global $_RQ,$_AR;
$_RQ['op']=$_RQ['op']?$_RQ['op']:'detail';
if($_RQ['op']=='detail'){
	$id=intval($_RQ['id']);
	if(!$id){
		exi('请选择商品','error','jy_zhongyi/index/');
	}
	$this->session('id',$id);
	$params=array('uniacid'=>$_SESSION['uniacid'],'id'=>$id);
	if($_RQ['keyword']){
		$params['title like']='%'.trim($_RQ['keyword']).'%';
	}
	$item=pdo_get('jy_zhongyi_goods',$params);
	$item['image']=tomedia($item['image']);
	$return['item']=$item;
	$return['sharedata']=array(
		'title'=>$item['title']?$item['title']:'商品详情',
		'desc'=>$item['desc']?$item['desc']:'商品说明',
		'link'=>custom_url('jy_zhongyi/goods_item//id='.$id,true),
		'image'=>tomedia($item['image']),
	);
	set_html('title',$item['title']);
	exi($return);
}

?>